package com.sunfeng.linkedlist;

import java.util.Stack;

/**
 * 演示
 */
public class TestStack {

    public static void main(String[] args) {
        Stack<String> stack = new Stack<String>();
        stack.push("Jack");
        stack.push("Tom");
        stack.push("Smith");
        while (stack.size() > 0) {
            System.out.println(stack.pop());
        }
    }
}
